<template>
  <div class="login-form">
    <h1>登陆</h1>
    <form>
    	<div>
    		<input type="text" v-model="user.name">	
    		<input type="text" v-model="user.password">
    		<p>{{user}}</p>
    	</div>
    	<div>
    		<el-button v-on:click="submit()">默认按钮</el-button>
    	</div>
    </form>
  </div>
</template>

<script>
export default {
  name: 'hello',
 
  data () {

    return {
      msg: 'Welcome to Your Vue.js App',
      user:{
	  	name:'',
	  	password:''
	  }
    }
  },
  methods:{
	  	submit:function(){
	  		console.log(this.user);
	  		// this.$http()
	  	}
	
  }
}
</script>

<!-- Add "scoped" attribute to limit CSS to this component only -->
<style scoped>
h1, h2 {
  font-weight: normal;
}

ul {
  list-style-type: none;
  padding: 0;
}

li {
  display: inline-block;
  margin: 0 10px;
}

a {
  color: #42b983;
}
</style>
